import type { RouteRecordRaw } from 'vue-router';
import RouterView from '@/layout/routerView/index.vue';
import menu from '@/assets/menuIcon/menu4.png';

const moduleName = 'auditing';

const routes: Array<RouteRecordRaw> = [
  {
    path: '/auditing',
    name: moduleName,
    component: RouterView,
    redirect: '/auditing/packet',
    meta: {
      title: '审核管理',
      icon: menu,
    },
    children: [
      {
        path: 'packet',
        name: `${moduleName}-packet`,
        component: () => import('@/views/auditing/packet/index.vue'),
        meta: {
          title: '数据审核',
        },
      },
      {
        path: 'speech',
        name: `${moduleName}-speech`,
        component: () => import('@/views/auditing/speech/index.vue'),
        meta: {
          title: '报告审核',
        },
      },
      {
        path: 'conAuditing',
        name: `${moduleName}-conAuditing`,
        component: () => import('@/views/consumables/conAuditing/index.vue'),
        meta: {
          title: '耗材审核',
        },
      },
      {
        path: 'auditing',
        name: `${moduleName}-auditing`,
        component: () => import('@/views/purchase/auditing/index.vue'),
        meta: {
          title: '采购审核',
        },
      },
    ],
  },
];

export default routes;
